package com.tchhy.provider.service.impl

import com.tchhy.provider.data.common.*
import com.tchhy.provider.data.healthy.request.CheckCaptchaReq
import com.tchhy.provider.data.healthy.response.CheckCaptchaRes
import com.tchhy.provider.data.partner.response.MedicineDetailResp
import com.tchhy.provider.data.partner.MedicineKitApplyInfo
import com.tchhy.provider.data.partner.MedicineKitSalesInfo
import com.tchhy.provider.data.partner.request.ApplyDrugExaminationListResponseInfo
import com.tchhy.provider.data.partner.request.CommitApplyDataReq
import com.tchhy.provider.data.partner.request.SavePaymentInfoReq
import com.tchhy.provider.data.partner.response.*
import com.tchhy.provider.repository.CommonRepository
import com.tchhy.provider.service.CommonService
import io.reactivex.Observable

/**
 * @author: admin
 * @date: 2019/8/20
 * @des:
 *
 **/
class CommonServiceImpl : CommonService {


    override fun sendCaptcha(smsVO: SmsVO): Observable<EmptyResp> {
        return commonRepository.sendCaptcha(smsVO)
    }

    override fun checkCaptcha(checkSmsVO: CheckCaptchaReq): Observable<BaseResp<CheckCaptchaRes>> {
        return  commonRepository.checkCaptcha(checkSmsVO)
    }

    private val commonRepository by lazy { CommonRepository() }


    /**
     * @description 安全退出
     * @param
     * @return
     * @author admin
     * @time 2019/8/20
     */
    override fun logout(): Observable<EmptyResp> {
        return commonRepository.logout()
    }

}